#include"process.h"
#include<time.h>
#include<stdlib.h>
double total=2048;
double once=0.1;

void download()
{
    double current=0.0;
    while(current<total)
    {
        int speed=rand()%10+1;
        current+=(speed*once);
        if(current>total)
        {
            current=total;
        }
        process(total,current);
        usleep(10000);
    }
    printf("\n");
}
int main()
{
    srand((unsigned int)time(NULL));
    download();
    //process();
    return 0;
}
